from selenium import webdriver
import time
from selenium.webdriver.common.by import By
from selenium.webdriver import ActionChains

d = webdriver.Chrome()
d.get('https://www.qq.com/')
d.maximize_window()
time.sleep(1)

wenzhang = d.find_element(By.CSS_SELECTOR, '[class=" bold"]')
wenzhang.click()
time.sleep(1)

all_windows = d.window_handles
d.switch_to.window( all_windows[1] )
time.sleep(1)
biaoti = d.title
zhengwen = d.find_element(By.CSS_SELECTOR, '[style="text-indent: 2em;"]')
zhengwen =zhengwen.text
time.sleep(1)